package com.ssy.lingxi.component.redis.lock;

/**
 * 锁信息
 * @author yzc
 * @version 2.0.0
 * @date 2021/7/15
 */
public class LockInfo {

    public LockInfo() {
    }

    public LockInfo(String lockKey, String lockValue, Long expire, Long acquireTimeout, int acquireCount, String lockInstance, RedisLockExecutor lockExecutor) {
        this.lockKey = lockKey;
        this.lockValue = lockValue;
        this.expire = expire;
        this.acquireTimeout = acquireTimeout;
        this.acquireCount = acquireCount;
        this.lockInstance = lockInstance;
        this.lockExecutor = lockExecutor;
    }

    /**
     * 锁名称
     */
    private String lockKey;

    /**
     * 锁值
     */
    private String lockValue;

    /**
     * 过期时间
     */
    private Long expire;

    /**
     * 获取锁超时时间
     */
    private Long acquireTimeout;

    /**
     * 获取锁次数
     */
    private int acquireCount;

    /**
     * 锁实例
     */
    private String lockInstance;

    /**
     * 锁执行器
     */
    private RedisLockExecutor lockExecutor;

    public String getLockKey() {
        return lockKey;
    }

    public void setLockKey(String lockKey) {
        this.lockKey = lockKey;
    }

    public String getLockValue() {
        return lockValue;
    }

    public void setLockValue(String lockValue) {
        this.lockValue = lockValue;
    }

    public Long getExpire() {
        return expire;
    }

    public void setExpire(Long expire) {
        this.expire = expire;
    }

    public Long getAcquireTimeout() {
        return acquireTimeout;
    }

    public void setAcquireTimeout(Long acquireTimeout) {
        this.acquireTimeout = acquireTimeout;
    }

    public int getAcquireCount() {
        return acquireCount;
    }

    public void setAcquireCount(int acquireCount) {
        this.acquireCount = acquireCount;
    }

    public String getLockInstance() {
        return lockInstance;
    }

    public void setLockInstance(String lockInstance) {
        this.lockInstance = lockInstance;
    }

    public RedisLockExecutor getLockExecutor() {
        return lockExecutor;
    }

    public void setLockExecutor(RedisLockExecutor lockExecutor) {
        this.lockExecutor = lockExecutor;
    }
}
